using Microsoft.Xna.Framework;
using Microsoft.Xna.Framework.Content;
using Microsoft.Xna.Framework.Graphics;
using FishFillets.GameComponents.Helpers;
using System;
using System.Collections.Generic;

namespace FishFillets.GameComponents
{
    public abstract class BaseItemComponent : DrawableGameComponent
    {
        public SpriteBatch SpriteBatch;
        
        protected readonly ContentManager contentManager;
        protected readonly AssetHelper contentAltManager;
        protected readonly string name;
        protected Vector2 drawPosition;
        
        protected bool isMoving;
        protected int moveStep, moveTotalSteps;
        protected int moveTotalBlocks;
        protected bool isTurningAround;

        #region ----- animation properties -------------------------------

        protected Texture2D texture;
        protected Dictionary<string, Texture2D> texturesDirLeft = new Dictionary<string, Texture2D>();
        protected Dictionary<string, Texture2D> texturesDirRight = new Dictionary<string, Texture2D>();
        public string CurrentAnim;
        public int AnimFrame = 0, AnimFrameCount = 0;
        public bool AnimRunning = false;

        #endregion

        protected BaseItemComponent(Game game, ContentManager contentManager, AssetHelper contentAltManager, string name)
            : base(game)
        {
            this.contentManager = contentManager;
            this.contentAltManager = contentAltManager;
            this.name = name;
        }
    }
}